package test.baojia.act.business;

import com.alibaba.fastjson.JSONObject;
import org.openqa.selenium.WebDriver;

import java.util.Map;
import java.util.Properties;

/**
 * 抽象批量执行脚本测试。
 */
public abstract class AbstractBatchTestJsonBusiness extends Business {

    @Override
    public void run(JSONObject context, WebDriver driver, Properties resource, JSONObject parentContext) throws Exception{
        super.run(context, driver, resource, parentContext);
        Map<String , Object> templateContext = this.makeTestJsonTemplateContext();
        this.runDefaultTestJson(this, templateContext , this.driver , this.resource , parentContext);
    }

    abstract protected Map<String , Object> makeTestJsonTemplateContext();


}
